package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.entity.AlertData;
import com.zzyl.entity.AlertRule;
import com.zzyl.vo.AlertDataVo;
import com.zzyl.vo.AlertRuleVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

@Mapper
public interface AlertDataMapper {
    Page<AlertDataVo> pageQuery(Long id, String deviceName, LocalDateTime endTime, LocalDateTime startTime, Integer status);

    List<AlertRuleVo> getAllAlertRule();

    int batchInsert(@Param("list") List<AlertData> list);

    List<AlertRule> seleteByFunctionId(String functionId, String iotId, String productKey);

}
